package com.yanma.erp.login.dao;

import com.yanma.erp.domain.SysUser;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

/**
 * Created by Kenry.Xian on 2016/2/12 0012.
 */

public interface SysUserDAO extends JpaRepository<SysUser, Long> {
    @Query("select user from SysUser user where user.userName = :username")
    SysUser findByName(@Param("username") String name);
}
